\hypertarget{classmiddleware_1_1DataManagerProxy}{
\section{middleware::DataManagerProxy Class Reference}
\label{classmiddleware_1_1DataManagerProxy}\index{middleware::DataManagerProxy@{middleware::DataManagerProxy}}
}


Proxy for communication between \hyperlink{classmiddleware_1_1Manager}{Manager} and \hyperlink{classmiddleware_1_1Worker}{Worker}.  




{\ttfamily \#include $<$data\_\-manager\_\-proxy.hpp$>$}

Inheritance diagram for middleware::DataManagerProxy:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[height=2.000000cm]{classmiddleware_1_1DataManagerProxy}
\end{center}
\end{figure}
\subsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\hyperlink{classmiddleware_1_1DataManagerProxy_ac287271fb1b4f204cef22e5314fdfd50}{$\sim$DataManagerProxy} ()
\item 
void \hyperlink{classmiddleware_1_1DataManagerProxy_ada9a4da98986da211f0551ac72c06fff}{send\_\-data} (\hyperlink{classmiddleware_1_1Data}{Data} data)  throw (ProxyException)
\item 
\hyperlink{classmiddleware_1_1Data}{Data} \hyperlink{classmiddleware_1_1DataManagerProxy_a42425bb4bd962b12cba2502ff3bc3239}{recv\_\-data} ()  throw (ProxyException)
\end{DoxyCompactItemize}
\subsection*{Friends}
\begin{DoxyCompactItemize}
\item 
class \hyperlink{classmiddleware_1_1DataManagerProxy_afdca94429b5f62b3460058f442cd9833}{DataProxyFactory}
\end{DoxyCompactItemize}


\subsection{Detailed Description}
Proxy for communication between \hyperlink{classmiddleware_1_1Manager}{Manager} and \hyperlink{classmiddleware_1_1Worker}{Worker}. Network interface used to let \hyperlink{classmiddleware_1_1Manager}{Manager} and \hyperlink{classmiddleware_1_1Worker}{Worker} communicate in order to send and receive \hyperlink{classmiddleware_1_1Data}{Data} of executable tasks. It is important to notice that constructor is private in order to let a factory perform instantiation of an object of this class. 

\subsection{Constructor \& Destructor Documentation}
\hypertarget{classmiddleware_1_1DataManagerProxy_ac287271fb1b4f204cef22e5314fdfd50}{
\index{middleware::DataManagerProxy@{middleware::DataManagerProxy}!$\sim$DataManagerProxy@{$\sim$DataManagerProxy}}
\index{$\sim$DataManagerProxy@{$\sim$DataManagerProxy}!middleware::DataManagerProxy@{middleware::DataManagerProxy}}
\subsubsection[{$\sim$DataManagerProxy}]{\setlength{\rightskip}{0pt plus 5cm}DataManagerProxy::$\sim$DataManagerProxy (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)}}
\label{classmiddleware_1_1DataManagerProxy_ac287271fb1b4f204cef22e5314fdfd50}
Destructor. 

\subsection{Member Function Documentation}
\hypertarget{classmiddleware_1_1DataManagerProxy_a42425bb4bd962b12cba2502ff3bc3239}{
\index{middleware::DataManagerProxy@{middleware::DataManagerProxy}!recv\_\-data@{recv\_\-data}}
\index{recv\_\-data@{recv\_\-data}!middleware::DataManagerProxy@{middleware::DataManagerProxy}}
\subsubsection[{recv\_\-data}]{\setlength{\rightskip}{0pt plus 5cm}{\bf Data} DataManagerProxy::recv\_\-data (
\begin{DoxyParamCaption}
{}
\end{DoxyParamCaption}
)  throw ({\bf ProxyException})}}
\label{classmiddleware_1_1DataManagerProxy_a42425bb4bd962b12cba2502ff3bc3239}
Receive data from a \hyperlink{classmiddleware_1_1Manager}{Manager}. \begin{DoxyReturn}{Returns}
Returns received data. 
\end{DoxyReturn}

\begin{DoxyExceptions}{Exceptions}
{\em \hyperlink{classmiddleware_1_1ProxyException}{ProxyException}} & Error during binding. \\
\hline
\end{DoxyExceptions}
\hypertarget{classmiddleware_1_1DataManagerProxy_ada9a4da98986da211f0551ac72c06fff}{
\index{middleware::DataManagerProxy@{middleware::DataManagerProxy}!send\_\-data@{send\_\-data}}
\index{send\_\-data@{send\_\-data}!middleware::DataManagerProxy@{middleware::DataManagerProxy}}
\subsubsection[{send\_\-data}]{\setlength{\rightskip}{0pt plus 5cm}void DataManagerProxy::send\_\-data (
\begin{DoxyParamCaption}
\item[{{\bf Data}}]{ data}
\end{DoxyParamCaption}
)  throw ({\bf ProxyException})}}
\label{classmiddleware_1_1DataManagerProxy_ada9a4da98986da211f0551ac72c06fff}
Sends \hyperlink{classmiddleware_1_1Data}{Data} to the specified \hyperlink{classmiddleware_1_1Worker}{Worker}. This function keeps into consideration the possibility that the destination \hyperlink{classmiddleware_1_1Worker}{Worker} might be unavailable for some reason. For this reason, 10 attempts are performed trying to connect to the \hyperlink{classmiddleware_1_1Worker}{Worker}. After 10 failures sending procedure is aborted and an exception is thrown. 
\begin{DoxyParams}{Parameters}
{\em data} & \hyperlink{classmiddleware_1_1Data}{Data} to send. \\
\hline
\end{DoxyParams}

\begin{DoxyExceptions}{Exceptions}
{\em \hyperlink{classmiddleware_1_1ProxyException}{ProxyException}} & Error during connection establishment. this exception is also thrown when 10 attempts to connect to destination \hyperlink{classmiddleware_1_1Worker}{Worker} failed and sending is aborted. \\
\hline
\end{DoxyExceptions}


\subsection{Friends And Related Function Documentation}
\hypertarget{classmiddleware_1_1DataManagerProxy_afdca94429b5f62b3460058f442cd9833}{
\index{middleware::DataManagerProxy@{middleware::DataManagerProxy}!DataProxyFactory@{DataProxyFactory}}
\index{DataProxyFactory@{DataProxyFactory}!middleware::DataManagerProxy@{middleware::DataManagerProxy}}
\subsubsection[{DataProxyFactory}]{\setlength{\rightskip}{0pt plus 5cm}friend class {\bf DataProxyFactory}\hspace{0.3cm}{\ttfamily  \mbox{[}friend\mbox{]}}}}
\label{classmiddleware_1_1DataManagerProxy_afdca94429b5f62b3460058f442cd9833}
To let factory build properly this object, we provide access to every part of it. 

The documentation for this class was generated from the following files:\begin{DoxyCompactItemize}
\item 
data\_\-manager\_\-proxy.hpp\item 
data\_\-manager\_\-proxy.cpp\end{DoxyCompactItemize}
